import 'package:boss/models/material.dart';
import 'package:json_annotation/json_annotation.dart';

import 'commodity.dart';

part 'store_menu.g.dart';

@JsonSerializable(explicitToJson: true)
class StoreMenu {
  StoreMenu();

  int menuId;
  int storeId;
  String menuName;
  int sort;
  @JsonKey(defaultValue: [])
  List<Material> commodityMeterialList;
  @JsonKey(defaultValue: [])
  List<Commodity> commodityList;
  @JsonKey(defaultValue: 0)
  int isPackages;
  @JsonKey(defaultValue: [])
  List<PrinterInfo> printerInfoList;
  String images;

  factory StoreMenu.fromJson(Map<String, dynamic> json) => _$StoreMenuFromJson(json);

  Map<String, dynamic> toJson() => _$StoreMenuToJson(this);
}
